<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>Document</title>
	</head>
	<body>
		<script type="text/javascript">
			//export命令
			//module.js
			let name="tom";
			let age=20;
			let phone='13813661234'
			let introduce=function(){
				return `My name is ${name}! I'm ${age} years old!`;
			};
			export{name,age,phone,introduce};
			
			//使用export命令主要事项
			//报错1
			// export 1;
			
			//报错2
			// var m=1;
			// export m;
			
			//正确写法一
			// export var m=1;
			
			//正确写法二
			// var m=1;
			// export{m};
			
			//正确写法三
			// var n=1;
			// export{n as m};
		</script>
	</body>
</html>